home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 7: Sunsite / Linux Cubed Series 7 - Sunsite Vol 1.iso / system / manual-p / olxvman.tgz / olxvman.tar / olxvman / src-test / olxvman_stubs.c < prev    next >
C/C++ Source or Header  |  1995-02-01  |  6KB  |  302 lines

  1. /*
  2.  * olxvman_stubs.c - Notify and event callback function stubs.
  3.  * This file was generated by `gxv' from `olxvman.G'.
  4.  */
  5.  
  6. #include <stdio.h>
  7. #include <sys/param.h>
  8. #include <sys/types.h>
  9. #include <xview/xview.h>
  10. #include <xview/panel.h>
  11. #include <xview/textsw.h>
  12. #include <xview/xv_xrect.h>
  13. #include "olxvman_ui.h"
  14.  
  15.  
  16. /*
  17.  * Global object definitions.
  18.  */
  19. olxvman_OLXVMan_objects    *Olxvman_OLXVMan;
  20. olxvman_SearchPopup_objects    *Olxvman_SearchPopup;
  21. olxvman_ManualPagePopup_objects    *Olxvman_ManualPagePopup;
  22.  
  23. #ifdef MAIN
  24.  
  25. /*
  26.  * Instance XV_KEY_DATA key.  An instance is a set of related
  27.  * user interface objects.  A pointer to an object's instance
  28.  * is stored under this key in every object.  This must be a
  29.  * global variable.
  30.  */
  31. Attr_attribute    INSTANCE;
  32.  
  33. main(argc, argv)
  34.     int    argc;
  35.     char    **argv;
  36. {
  37.     /*
  38.      * Initialize XView.
  39.      */
  40.     xv_init(XV_INIT_ARGC_PTR_ARGV, &argc, argv, NULL);
  41.     INSTANCE = xv_unique_key();
  42.     
  43.     /*
  44.      * Initialize user interface components.
  45.      * Do NOT edit the object initializations by hand.
  46.      */
  47.     Olxvman_OLXVMan = olxvman_OLXVMan_objects_initialize(NULL, NULL);
  48.     Olxvman_SearchPopup = olxvman_SearchPopup_objects_initialize(NULL, Olxvman_OLXVMan->OLXVMan);
  49.     Olxvman_ManualPagePopup = olxvman_ManualPagePopup_objects_initialize(NULL, Olxvman_OLXVMan->OLXVMan);
  50.     
  51.     
  52.     /*
  53.      * Turn control over to XView.
  54.      */
  55.     xv_main_loop(Olxvman_OLXVMan->OLXVMan);
  56.     exit(0);
  57. }
  58.  
  59. #endif
  60.  
  61.  
  62. /*
  63.  * Menu handler for `OptionMenu (Search...)'.
  64.  */
  65. Menu_item
  66. SearchHandler(item, op)
  67.     Menu_item    item;
  68.     Menu_generate    op;
  69. {
  70.     olxvman_OLXVMan_objects * ip = (olxvman_OLXVMan_objects *) xv_get(item, XV_KEY_DATA, INSTANCE);
  71.     
  72.     switch (op) {
  73.     case MENU_DISPLAY:
  74.         break;
  75.  
  76.     case MENU_DISPLAY_DONE:
  77.         break;
  78.  
  79.     case MENU_NOTIFY:
  80.         fputs("olxvman: SearchHandler: MENU_NOTIFY\n", stderr);
  81.         
  82.         /* gxv_start_connections DO NOT EDIT THIS SECTION */
  83.  
  84.         /* gxv_end_connections */
  85.  
  86.         break;
  87.  
  88.     case MENU_NOTIFY_DONE:
  89.         break;
  90.     }
  91.     return item;
  92. }
  93.  
  94. /*
  95.  * Menu handler for `OptionMenu (Show Version)'.
  96.  */
  97. Menu_item
  98. ShowVersionHandler(item, op)
  99.     Menu_item    item;
  100.     Menu_generate    op;
  101. {
  102.     olxvman_OLXVMan_objects * ip = (olxvman_OLXVMan_objects *) xv_get(item, XV_KEY_DATA, INSTANCE);
  103.     
  104.     switch (op) {
  105.     case MENU_DISPLAY:
  106.         break;
  107.  
  108.     case MENU_DISPLAY_DONE:
  109.         break;
  110.  
  111.     case MENU_NOTIFY:
  112.         fputs("olxvman: ShowVersionHandler: MENU_NOTIFY\n", stderr);
  113.         
  114.         /* gxv_start_connections DO NOT EDIT THIS SECTION */
  115.  
  116.         /* gxv_end_connections */
  117.  
  118.         break;
  119.  
  120.     case MENU_NOTIFY_DONE:
  121.         break;
  122.     }
  123.     return item;
  124. }
  125.  
  126. /*
  127.  * Menu handler for `OptionMenu (Print Current Page)'.
  128.  */
  129. Menu_item
  130. PrintHandler(item, op)
  131.     Menu_item    item;
  132.     Menu_generate    op;
  133. {
  134.     olxvman_OLXVMan_objects * ip = (olxvman_OLXVMan_objects *) xv_get(item, XV_KEY_DATA, INSTANCE);
  135.     
  136.     switch (op) {
  137.     case MENU_DISPLAY:
  138.         break;
  139.  
  140.     case MENU_DISPLAY_DONE:
  141.         break;
  142.  
  143.     case MENU_NOTIFY:
  144.         fputs("olxvman: PrintHandler: MENU_NOTIFY\n", stderr);
  145.         
  146.         /* gxv_start_connections DO NOT EDIT THIS SECTION */
  147.  
  148.         /* gxv_end_connections */
  149.  
  150.         break;
  151.  
  152.     case MENU_NOTIFY_DONE:
  153.         break;
  154.     }
  155.     return item;
  156. }
  157.  
  158. /*
  159.  * Menu handler for `OptionMenu (Quit)'.
  160.  */
  161. Menu_item
  162. QuitHandler(item, op)
  163.     Menu_item    item;
  164.     Menu_generate    op;
  165. {
  166.     olxvman_OLXVMan_objects * ip = (olxvman_OLXVMan_objects *) xv_get(item, XV_KEY_DATA, INSTANCE);
  167.     
  168.     switch (op) {
  169.     case MENU_DISPLAY:
  170.         break;
  171.  
  172.     case MENU_DISPLAY_DONE:
  173.         break;
  174.  
  175.     case MENU_NOTIFY:
  176.         fputs("olxvman: QuitHandler: MENU_NOTIFY\n", stderr);
  177.         
  178.         /* gxv_start_connections DO NOT EDIT THIS SECTION */
  179.  
  180.         /* gxv_end_connections */
  181.  
  182.         break;
  183.  
  184.     case MENU_NOTIFY_DONE:
  185.         break;
  186.     }
  187.     return item;
  188. }
  189.  
  190. /*
  191.  * Notify callback function for `ManualSections'.
  192.  */
  193. int
  194. ManualSectionNotify(item, string, client_data, op, event, row)
  195.     Panel_item    item;
  196.     char        *string;
  197.     Xv_opaque    client_data;
  198.     Panel_list_op    op;
  199.     Event        *event;
  200.     int        row;
  201. {
  202.     olxvman_OLXVMan_objects *ip = (olxvman_OLXVMan_objects *) xv_get(item, XV_KEY_DATA, INSTANCE);
  203.     
  204.     switch(op) {
  205.     case PANEL_LIST_OP_DESELECT:
  206.         fprintf(stderr, "olxvman: ManualSectionNotify: PANEL_LIST_OP_DESELECT: %s\n",string);
  207.         break;
  208.  
  209.     case PANEL_LIST_OP_SELECT:
  210.         fprintf(stderr, "olxvman: ManualSectionNotify: PANEL_LIST_OP_SELECT: %s\n",string);
  211.         break;
  212.  
  213.     case PANEL_LIST_OP_VALIDATE:
  214.         fprintf(stderr, "olxvman: ManualSectionNotify: PANEL_LIST_OP_VALIDATE: %s\n",string);
  215.         break;
  216.  
  217.     case PANEL_LIST_OP_DELETE:
  218.         fprintf(stderr, "olxvman: ManualSectionNotify: PANEL_LIST_OP_DELETE: %s\n",string);
  219.         break;
  220.     }
  221.     
  222.     /* gxv_start_connections DO NOT EDIT THIS SECTION */
  223.  
  224.     /* gxv_end_connections */
  225.  
  226.     return XV_OK;
  227. }
  228.  
  229. /*
  230.  * Notify callback function for `ManualPages'.
  231.  */
  232. int
  233. ManualPageNotify(item, string, client_data, op, event, row)
  234.     Panel_item    item;
  235.     char        *string;
  236.     Xv_opaque    client_data;
  237.     Panel_list_op    op;
  238.     Event        *event;
  239.     int        row;
  240. {
  241.     olxvman_OLXVMan_objects *ip = (olxvman_OLXVMan_objects *) xv_get(item, XV_KEY_DATA, INSTANCE);
  242.     
  243.     switch(op) {
  244.     case PANEL_LIST_OP_DESELECT:
  245.         fprintf(stderr, "olxvman: ManualPageNotify: PANEL_LIST_OP_DESELECT: %s\n",string);
  246.         break;
  247.  
  248.     case PANEL_LIST_OP_SELECT:
  249.         fprintf(stderr, "olxvman: ManualPageNotify: PANEL_LIST_OP_SELECT: %s\n",string);
  250.         break;
  251.  
  252.     case PANEL_LIST_OP_VALIDATE:
  253.         fprintf(stderr, "olxvman: ManualPageNotify: PANEL_LIST_OP_VALIDATE: %s\n",string);
  254.         break;
  255.  
  256.     case PANEL_LIST_OP_DELETE:
  257.         fprintf(stderr, "olxvman: ManualPageNotify: PANEL_LIST_OP_DELETE: %s\n",string);
  258.         break;
  259.     }
  260.     
  261.     /* gxv_start_connections DO NOT EDIT THIS SECTION */
  262.  
  263.     /* gxv_end_connections */
  264.  
  265.     return XV_OK;
  266. }
  267.  
  268. /*
  269.  * Notify callback function for `ManualButton'.
  270.  */
  271. void
  272. SearchNotify(item, event)
  273.     Panel_item    item;
  274.     Event        *event;
  275. {
  276.     olxvman_SearchPopup_objects *ip = (olxvman_SearchPopup_objects *) xv_get(item, XV_KEY_DATA, INSTANCE);
  277.     
  278.     fputs("olxvman: SearchNotify\n", stderr);
  279.     
  280.     /* gxv_start_connections DO NOT EDIT THIS SECTION */
  281.  
  282.     /* gxv_end_connections */
  283.  
  284. }
  285.  
  286. /*
  287.  * Done callback function for `ManualPagePopup'.
  288.  */
  289. void
  290. ManualPagePinned(frame)
  291.     Frame        frame;
  292. {
  293.     fputs("olxvman: ManualPagePinned\n", stderr);
  294.     xv_set(frame, XV_SHOW, FALSE, NULL);
  295.     
  296.     /* gxv_start_connections DO NOT EDIT THIS SECTION */
  297.  
  298.     /* gxv_end_connections */
  299.  
  300. }
  301.  
  302.